import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.BeforeAll;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.edge.EdgeDriver;
import org.openqa.selenium.edge.EdgeOptions;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: DELL
 * Date: 2023-08-23
 * Time: 18:57
 */

/**
 * 提供前置的初始化驱动以及结束后的退出浏览器
 */
public class InitAndEnd {

    static WebDriver webDriver;

    @BeforeAll
    static void SetUp() {
        EdgeOptions options = new EdgeOptions();
        options.addArguments("--remote-allow-origins=*");
        webDriver = new EdgeDriver(options);
    }

    @AfterAll
    static void TearDown() {
        webDriver.quit();
    }

}
